// 导入组件
import Vue from 'vue';
import Router from 'vue-router';
// 首页
import index from '../pages/index';
import ApiConfig from '../pages/apiManage/apiConfig';
import ApiList from '../pages/apiManage/apiList';
import ApiTest from '../pages/apiManage/apiTest'


// 启用路由
Vue.use(Router);

// 导出路由 
export default new Router({
    routes: [
        {
            path: '/index',
            name: '主页',
            component: index,
            children: [
                {
                    path: '/apiManage/apiConfig',
                    name: 'api配置',
                    component: ApiConfig
                },
                {
                    path: '/apiManage/apiList',
                    name: 'api列表',
                    component: ApiList
                },
                {
                    path: '/apiManage/apiTest',
                    name: 'api测试',
                    component: ApiTest
                }
            ]
        }
    ]
});